// Decompiled by Jad v1.5.8g. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://www.kpdus.com/jad.html
// Decompiler options: packimports(3) 

package com.nnee.p_pr.p_activity.p_view;

import android.text.TextUtils;
import android.view.View;
import android.webkit.URLUtil;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.ListView;
import android.widget.Toast;
import com.nnee.p_b.p_a.cls_ab;
import com.nnee.p_pr.p_activity.cls_ArticleGalleryActivity;
import com.nnee.p_pr.p_activity.cls_dc;
import com.nnee.p_pr.p_activity.p_view.WebViews.WebViewAdapter;
import com.nnee.p_pr.p_atom.cls_g;
import com.nnee.p_pr.p_atom.cls_o;
import com.nnee.p_pr.p_atom.cls_r;
import com.nnee.p_pr.p_atom.t;
import com.nnee.p_pr.p_atom.cls_u;
import com.nnee.p_pr.cls_b;
import com.nnee.p_pr.p_prot.cls_d;
import java.util.LinkedList;
import java.util.List;

// Referenced classes of package com.nnee.p_pr.p_activity.view:
//            PrisArticleView

class ad extends cls_b
{

    ad(PrisArticleView prisarticleview)
    {
        a = prisarticleview;
        super();
    }

    public void a()
    {
        PrisArticleView.l(a).setVisibility(8);
        PrisArticleView.m(a).setVisibility(8);
        com.nnee.p_pr.p_activity.p_view.PrisArticleView.b(a, false);
    }

    public void a(int j, int i1, String s)
    {
        if(PrisArticleView.A(a).contains(new Integer(j)))
        {
            PrisArticleView.A(a).remove(new Integer(j));
            if(PrisArticleView.C(a) == PrisArticleView.p(a))
                dc.a(PrisArticleView.a(a), i1);
        }
    }

    public void a(int j, ab ab1)
    {
        if(PrisArticleView.A(a).remove(new Integer(j)) && PrisArticleView.c(a) != null && PrisArticleView.h(a) != null && ab1.b() != null)
        {
            StringBuilder stringbuilder = new StringBuilder();
            stringbuilder.append("javascript:refreshImg('");
            stringbuilder.append(ab1.a());
            stringbuilder.append("','");
            stringbuilder.append(ab1.b());
            stringbuilder.append("')");
            PrisArticleView.h(a).loadUrl(stringbuilder.toString());
            PrisArticleView.h(a).k();
        }
    }

    public void a(int j, cls_d d1)
    {
_L2:
        return;
        if(!PrisArticleView.A(a).contains(new Integer(j)) || d1 == null) goto _L2; else goto _L1
_L1:
        if(d1.h.size() > 0)
        {
            if(com.nnee.p_b.p_a.cls_d.h().i())
                PrisArticleView.N(a);
            if(PrisArticleView.A(a).contains(new Integer(j)))
            {
                PrisArticleView.A(a).remove(new Integer(j));
                Toast.makeText(PrisArticleView.a(a), 0x7f0a009a, 0).show();
            }
            if(PrisArticleView.G(a) != null && PrisArticleView.G(a).h != null && ((u)PrisArticleView.G(a).h.getFirst()).V().equals(((u)d1.h.getFirst()).V()))
            {
                com.nnee.p_pr.p_activity.p_view.PrisArticleView.d(a, true);
                PrisArticleView.H(a).setVisibility(0);
                a.c(PrisArticleView.p(a), cls_ArticleGalleryActivity.i, Boolean.valueOf(true));
            }
        } else
        if(d1.i.size() > 0 && PrisArticleView.A(a).contains(new Integer(j)))
        {
            PrisArticleView.A(a).remove(new Integer(j));
            Toast.makeText(PrisArticleView.a(a), ((r)d1.i.getFirst()).e(), 0).show();
        }
        if(true) goto _L2; else goto _L3
_L3:
    }

    public void a(int j, String s, boolean flag)
    {
        if(PrisArticleView.O(a) == j)
        {
            if(!flag && s != null)
                com.nnee.p_pr.p_activity.p_view.PrisArticleView.b(a, s);
            com.nnee.p_pr.p_activity.p_view.PrisArticleView.g(a, 1);
        }
    }

    public void c(int j)
    {
_L2:
        return;
        if(!PrisArticleView.A(a).remove(new Integer(j)) || PrisArticleView.c(a) == null) goto _L2; else goto _L1
_L1:
        List list = PrisArticleView.c(a).c();
        if(list == null || list.size() == 0)
            PrisArticleView.a(a, true);
        if(true) goto _L2; else goto _L3
_L3:
    }

    public void d(int j, int i1, String s, boolean flag)
    {
        if(PrisArticleView.A(a).contains(new Integer(j)))
        {
            if(PrisArticleView.C(a) == PrisArticleView.p(a))
                dc.a(PrisArticleView.a(a), i1);
            PrisArticleView.A(a).remove(new Integer(j));
            if(PrisArticleView.k(a))
            {
                PrisArticleView.l(a).setVisibility(8);
                PrisArticleView.m(a).setVisibility(8);
            }
            PrisArticleView.e(a, false);
            if(flag)
            {
                PrisArticleView.w(a).removeFooterView(PrisArticleView.J(a));
                com.nnee.p_pr.p_activity.p_view.PrisArticleView.b(a, false);
            }
        }
    }

    public void d(int j, cls_d d1, boolean flag)
    {
_L2:
        return;
        if(d1 == null || !PrisArticleView.A(a).contains(new Integer(j))) goto _L2; else goto _L1
_L1:
        PrisArticleView.A(a).remove(new Integer(j));
        if(PrisArticleView.k(a))
        {
            PrisArticleView.l(a).setVisibility(8);
            PrisArticleView.m(a).setVisibility(8);
        }
        PrisArticleView.e(a, false);
        PrisArticleView.w(a).removeFooterView(PrisArticleView.J(a));
        com.nnee.p_pr.p_activity.p_view.PrisArticleView.b(a, false);
        PrisArticleView.a(a, d1, flag);
        if(1 != PrisArticleView.K(a))
            PrisArticleView.f(a, 1);
        String s = PrisArticleView.L(a);
        PrisArticleView.a(a, null);
        if(d1.g != null)
        {
            String s1 = d1.g.b(g.i);
            if(!TextUtils.isEmpty(s1))
                if(s1.equals(s))
                    PrisArticleView.a(a, null);
                else
                    PrisArticleView.a(a, s1);
        }
        if(true) goto _L2; else goto _L3
_L3:
    }

    public void i(int j, int i1, String s)
    {
        if(PrisArticleView.A(a).contains(new Integer(j)))
        {
            PrisArticleView.A(a).remove(new Integer(j));
            if(PrisArticleView.C(a) == PrisArticleView.p(a))
                dc.a(PrisArticleView.a(a), i1);
        }
    }

    public void k(int j, cls_d d1)
    {
        if(PrisArticleView.A(a).contains(new Integer(j))) goto _L2; else goto _L1
_L1:
        return;
_L2:
        PrisArticleView.A(a).remove(new Integer(j));
        if(d1 != null)
            if(d1.j.size() > 0)
            {
                Toast.makeText(PrisArticleView.a(a), 0x7f0a009b, 0).show();
                com.nnee.p_pr.p_activity.p_view.PrisArticleView.d(a, false);
                PrisArticleView.H(a).setVisibility(4);
                a.c(PrisArticleView.p(a), cls_ArticleGalleryActivity.j, Boolean.valueOf(false));
                if(PrisArticleView.G(a) != null && PrisArticleView.G(a).h != null && ((u)PrisArticleView.G(a).h.getFirst()).V().equals(((o)d1.j.getFirst()).a()))
                {
                    com.nnee.p_pr.p_activity.p_view.PrisArticleView.d(a, false);
                    PrisArticleView.H(a).setVisibility(4);
                }
            } else
            if(d1.i.size() > 0 && PrisArticleView.A(a).contains(new Integer(j)))
            {
                PrisArticleView.A(a).remove(new Integer(j));
                Toast.makeText(PrisArticleView.a(a), ((r)d1.i.getFirst()).e(), 0).show();
            }
        if(true) goto _L1; else goto _L3
_L3:
    }

    public void l(int j, int i1, String s)
    {
        if(PrisArticleView.A(a).contains(new Integer(j))) goto _L2; else goto _L1
_L1:
        return;
_L2:
        PrisArticleView.A(a).remove(new Integer(j));
        PrisArticleView.c(a, 0);
        PrisArticleView.a(a, false);
        if(PrisArticleView.k(a))
        {
            PrisArticleView.l(a).setVisibility(8);
            PrisArticleView.m(a).setVisibility(8);
        }
        if(PrisArticleView.C(a) == PrisArticleView.p(a) && PrisArticleView.c(a) == null)
            dc.a(PrisArticleView.a(a), i1);
        if(PrisArticleView.c(a) == null)
            PrisArticleView.h(a).loadDataWithBaseURL(null, PrisArticleView.F(a), "text/html", "UTF-8", null);
        if(true) goto _L1; else goto _L3
_L3:
    }

    public void l(int j, cls_d d1)
    {
        Integer integer = new Integer(j);
        if(d1 != null) goto _L2; else goto _L1
_L1:
        if(PrisArticleView.A(a).contains(integer))
            PrisArticleView.A(a).remove(integer);
_L4:
        return;
_L2:
        if(PrisArticleView.A(a).contains(integer))
        {
            cls_PrisArticleView prisarticleview = a;
            boolean flag;
            if(PrisArticleView.B(a) || PrisArticleView.C(a) == PrisArticleView.p(a))
                flag = true;
            else
                flag = false;
            PrisArticleView.a(prisarticleview, d1, flag, true);
            if(d1.h.size() > 0)
            {
                cls_u u1 = (u)d1.h.getFirst();
                String s = u1.b(g.D);
                if(s != null)
                    PrisArticleView.a(a, 902, null, s, u1.V());
            }
        }
        if(PrisArticleView.C(a) == PrisArticleView.p(a) && !PrisArticleView.D(a))
        {
            PrisArticleView.c(a, true);
            PrisArticleView.E(a);
        }
        if(true) goto _L4; else goto _L3
_L3:
    }

    public void m(int j, cls_d d1)
    {
_L2:
        return;
        if(!PrisArticleView.A(a).remove(new Integer(j)) || d1 == null) goto _L2; else goto _L1
_L1:
        d d2 = PrisArticleView.G(a);
        PrisArticleView.a(a, d1);
        if(d2 != null)
            d2.k();
        if(PrisArticleView.G(a).h != null)
        {
            cls_u u1 = (u)PrisArticleView.G(a).h.getFirst();
            if(u1 != null)
            {
                if(t.a == u1.at())
                {
                    com.nnee.p_pr.p_activity.p_view.PrisArticleView.d(a, true);
                    PrisArticleView.H(a).setVisibility(0);
                    a.c(PrisArticleView.p(a), cls_ArticleGalleryActivity.i, Boolean.valueOf(true));
                } else
                {
                    com.nnee.p_pr.p_activity.p_view.PrisArticleView.d(a, false);
                    PrisArticleView.H(a).setVisibility(8);
                    a.c(PrisArticleView.p(a), cls_ArticleGalleryActivity.j, Boolean.valueOf(false));
                }
                com.nnee.p_pr.p_activity.p_view.PrisArticleView.d(a, u1.ab());
                a.c(PrisArticleView.p(a), cls_ArticleGalleryActivity.q, Integer.valueOf(PrisArticleView.I(a)));
                PrisArticleView.e(a, u1.aa());
            }
        }
        if(true) goto _L2; else goto _L3
_L3:
    }

    public void n(int j, int i1, String s)
    {
        if(PrisArticleView.A(a).remove(new Integer(j)) && PrisArticleView.k(a))
        {
            PrisArticleView.l(a).setVisibility(8);
            PrisArticleView.m(a).setVisibility(8);
        }
    }

    public void n(int j, cls_d d1)
    {
        if(d1 != null) goto _L2; else goto _L1
_L1:
        return;
_L2:
        if(!PrisArticleView.A(a).contains(new Integer(j))) goto _L4; else goto _L3
_L3:
        PrisArticleView.A(a).remove(new Integer(j));
        Toast.makeText(PrisArticleView.a(a), 0x7f0a0099, 0).show();
_L6:
        if(PrisArticleView.c(a) == null);
        if(1 == PrisArticleView.M(a))
        {
            PrisArticleView.a(a, null);
            com.nnee.p_pr.p_activity.p_view.PrisArticleView.b(a, PrisArticleView.c(a));
        }
        cls_u u1 = (u)PrisArticleView.c(a).h.getFirst();
        if(u1 == null)
            break; /* Loop/switch isn't completed */
        String s = u1.b(g.D);
        if(s == null)
            break; /* Loop/switch isn't completed */
        if(!URLUtil.isNetworkUrl(s))
            s = (new StringBuilder()).append("http://easyread.163.com").append(s).toString();
        PrisArticleView.a(a, 902, null, s, u1.V());
        break; /* Loop/switch isn't completed */
        NullPointerException nullpointerexception;
        nullpointerexception;
        nullpointerexception.printStackTrace();
        break; /* Loop/switch isn't completed */
        Exception exception;
        exception;
        throw exception;
_L4:
        if(PrisArticleView.c(a) == null) goto _L6; else goto _L5
_L5:
        boolean flag = d1.a().equals(((u)PrisArticleView.c(a).h.getFirst()).V());
        if(flag) goto _L6; else goto _L1
    }

    public void o(int j, cls_d d1)
    {
        if(PrisArticleView.A(a).contains(new Integer(j)))
        {
            PrisArticleView.A(a).remove(new Integer(j));
            Toast.makeText(PrisArticleView.a(a), 0x7f0a00a0, 0).show();
            if(PrisArticleView.c(a) != null)
            {
                if(1 == PrisArticleView.M(a))
                {
                    PrisArticleView.a(a, null);
                    com.nnee.p_pr.p_activity.p_view.PrisArticleView.b(a, PrisArticleView.c(a));
                }
                cls_u u1 = (u)PrisArticleView.c(a).h.getFirst();
                if(u1 != null)
                {
                    String s = u1.b(g.D);
                    if(s != null)
                        PrisArticleView.a(a, 902, null, s, null);
                }
            }
        }
        break MISSING_BLOCK_LABEL_172;
        NullPointerException nullpointerexception;
        nullpointerexception;
        nullpointerexception.printStackTrace();
        break MISSING_BLOCK_LABEL_172;
        Exception exception;
        exception;
        throw exception;
    }

    public void p(int j, int i1, String s)
    {
        if(PrisArticleView.A(a).contains(new Integer(j)))
        {
            PrisArticleView.A(a).remove(new Integer(j));
            if(PrisArticleView.C(a) == PrisArticleView.p(a))
                dc.a(PrisArticleView.a(a), i1);
        }
_L1:
        return;
        NullPointerException nullpointerexception;
        nullpointerexception;
        nullpointerexception.printStackTrace();
          goto _L1
        Exception exception;
        exception;
        throw exception;
    }

    public void q(int j, int i1, String s)
    {
        if(PrisArticleView.A(a).contains(new Integer(j)))
        {
            PrisArticleView.A(a).remove(new Integer(j));
            if(PrisArticleView.C(a) == PrisArticleView.p(a))
                dc.a(PrisArticleView.a(a), i1);
        }
_L1:
        return;
        NullPointerException nullpointerexception;
        nullpointerexception;
        nullpointerexception.printStackTrace();
          goto _L1
        Exception exception;
        exception;
        throw exception;
    }

    public void q(int j, cls_d d1)
    {
        if(PrisArticleView.A(a).contains(new Integer(j))) goto _L2; else goto _L1
_L1:
        return;
_L2:
        PrisArticleView.A(a).remove(new Integer(j));
        if(d1 != null && d1.h.size() != 0)
            Toast.makeText(PrisArticleView.a(a), 0x7f0a009c, 0).show();
        if(true) goto _L1; else goto _L3
_L3:
    }

    public void t(int j, int i1, String s)
    {
        if(PrisArticleView.A(a).contains(new Integer(j)))
        {
            PrisArticleView.A(a).remove(new Integer(j));
            dc.a(PrisArticleView.a(a), i1);
        }
    }

    final cls_PrisArticleView a;
}
